package lang.thread;

public class T {

	public static void printInfo(Thread t, String msg) {
		System.out.println();
		System.out.print(msg + " info:");
		System.out.println(t);
		System.out.println(msg + " id:" + t.getId());
		System.out.println(msg + " name:" + t.getName());
		System.out.println(msg + " 优先级:" + t.getPriority());
	}

	public static void printGroupInfo(ThreadGroup tg) {
		System.out.println();
		System.out.println("group name : " + tg.getName());
		System.out.println("group active count : " + tg.activeCount());
		System.out.println("group active group count : "
				+ tg.activeGroupCount());
		tg.list();
	}

}
